<template>
	<el-card class="form-container">
		<el-form :model="userDetail"   label-width="100px">
			<el-form-item label="昵称" prop="loginName">
				<el-input v-model="userDetail.userNickName"  readonly></el-input>
			</el-form-item>
			<el-form-item label="昵称" prop="userNickName">
				<el-input v-model="userDetail.userNickName"  readonly placeholder="请输入昵称"></el-input>
			</el-form-item>
			<el-form-item label="邮箱" prop="userEmail">
				<el-input v-model="userDetail.userEmail"  readonly placeholder="请输入电子邮件"></el-input>
			</el-form-item>
			<el-form-item label="手机号" prop="userPhone">
				<el-input v-model="userDetail.userPhone"  readonly placeholder="请输入手机号" ></el-input>
			</el-form-item>
			<el-form-item label="用户状态" prop="userStatus">
				<el-radio-group v-model="userDetail.userStatus" >
					<el-radio disabled label="1">启用</el-radio>
					<el-radio disabled label="2">禁用</el-radio>
				</el-radio-group>
			</el-form-item>
			<el-form-item label="创建时间" prop="createTime">
				<el-input v-model="userDetail.createTime"  readonly></el-input>
			</el-form-item>
			<el-form-item label="修改时间" prop="updateTime">
				<el-input v-model="userDetail.updateTime"  readonly></el-input>
			</el-form-item>
			<el-form-item label="最后登录IP" prop="userLastLoginIp">
				<el-input v-model="userDetail.userLastLoginTime"  readonly></el-input>
			</el-form-item>
			<el-form-item label="最后登录时间" prop="userLastLoginTime">
				<el-input v-model="userDetail.userLastLoginTime"  readonly></el-input>
			</el-form-item>
			<el-form-item>
				<el-button @click="close">关闭</el-button>
			</el-form-item>
		</el-form>
	</el-card>
</template>

<script>
import { findSystemUserDetail } from '@/api/admin/systemUser'
export default{
	name: 'view-user',
	data(){
		return {
			userDetail: {}
		}
	},
	created() {
		this.view(this.$route.query.id)
	},
	methods:{
		view(val){
			findSystemUserDetail(val).then(res => {
				console.log('查询返回结果',res)
				this.userDetail = res.data.responseData
			})
		},
		close(){
			this.$router.go(-1)
		}
	}
}
</script>

<style>
</style>
